package javaz.jaxb.xml;

import java.util.ArrayList;
import java.util.List;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlSchemaType;

@XmlAccessorType(XmlAccessType.FIELD)
@XmlRootElement(name = "Countries")
public class DataCountry {
	
	public static final String XSD = "/resources/jaxb/JaxbXMLSchema.xsd";
	public static final String DATA = "/resources/jaxb/JaxbXMLData.xml";

	@XmlAttribute(name = "Name", required = true)
	@XmlSchemaType(name = "string")
	private String name = "Country name";

	@XmlElement(name = "Customers", required = true)
	private List<DataCustomer> customers = new ArrayList<>();

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public List<DataCustomer> getCustomers() {
		return customers;
	}

	public void setCustomers(List<DataCustomer> customers) {
		this.customers = customers;
	}

}
